home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Games Machine 76
/
XENIATGM66.iso
/
Indiana Jones
/
Indiana Jones.exe
/
RESOURCE
/
PREVIEW.GOB
/
cog_riv_ambb2spatha.cog
< prev
next >
Wrap
Text File
|
1999-11-15
|
3KB
|
101 lines
# Jones 3D Cog Script
#
# RIV_AmbB2SPathA.cog
#
# Plays random ambient sounds at random positions and drops
# snow at all the positions all the time.
#
# [TRM]
#
# (C) 1999 LucasArts Entertainment Co. All Rights Reserved
# ========================================================================================
symbols
message entered
message pulse
thing soundPos0 nolink
thing soundPos1 nolink
thing soundPos2 nolink
thing soundPos3 nolink
thing soundPos4 nolink
thing soundPos5 nolink
thing soundPos6 nolink
thing soundPos7 nolink
sector start_Amb1 linkID=1
sector start_Amb2 linkID=1
sector start_Amb3 linkID=1
sector stop_Amb1 linkID=0
sector stop_Amb2 linkID=0
sound ambient0=shw_amb1.wav local
sound ambient1=shw_amb2.wav local
sound ambient2=shw_amb3.wav local
sound ambient3=shw_amb4.wav local
sound ambient4=shw_amb5.wav local
sound ambient5=shw_amb6.wav local
sound ambient6=shw_amb7.wav local
template tpl_Snow=skitosnow local
int playing=0 local
int randNum local
sound snd_Wolf=fol_wolf_talk.wav local
end
# ========================================================================================
code
entered:
if((GetSenderID() == 1) && (playing == 0))
{
playing = 1;
setpulse(2.0);
}
if(GetSenderID() == 0)
{
playing = 0;
SetPulse(0.0);
}
return;
# ========================================================================================
pulse:
PlaySoundThing(ambient0[RandBetween(0, 6)], soundPos0[RandBetween(0, 7)], 1.0, 15, 30, 0);
randNum = RandBetween(1, 10);
if(randNum == 5)
{
PlaySoundThing(snd_Wolf, soundPos0[RandBetween(0, 7)], 0.5, 15, 30, 0);
}
if(GetPerformanceLevel() >= 2)
{
CreateThing(tpl_Snow, soundPos0);
CreateThing(tpl_Snow, soundPos1);
CreateThing(tpl_Snow, soundPos2);
CreateThing(tpl_Snow, soundPos3);
CreateThing(tpl_Snow, soundPos4);
CreateThing(tpl_Snow, soundPos5);
CreateThing(tpl_Snow, soundPos6);
CreateThing(tpl_Snow, soundPos7);
}
return;
# ========================================================================================
end